Skip to main content

All Questions

2votes
1answer
314views

PHP OOP: Configuring MySQL DB & query w/ Twig

I decided to up my PHP game and learn some OOP. I am re-building my website from procedural to OOP, but since I don't want to use a full framework I fiddle with some components. As a router I use ...
bender's user avatar
7votes
2answers
229views

Connect to MYSQL database in PHP with prepared statements

I have recently learned about using the functions exposed by the PDO extension. I created a db class which can handle common actions like create, update, delete and select. Is this method a correct ...
Sanidhya's user avatar
4votes
2answers
304views

OOP - Contact Form PHP Backend - Procedural to OOP - Dynamic MySQL Prepared Statement PHP

I just converted procedural code to OOP code. Is there any performance or security issue with this code or what should I consider further? interface ...
Thaninayagam's user avatar
4votes
2answers
457views

API for SQL queries with PHP PDO

I'm writing a very simple CRUD application, and I'm wondering if the way I'm using static methods throughout the code makes sense. I'd very much like to simplify ...
GingerBadger's user avatar
1vote
2answers
134views

Repeated DB connection at max user connections

I am trying to create class with connect to mysql database. And if there is max number of connections I want to wait and try it again. I figured out, how it can works, but I am not sure, if its the ...
Tomáš Kretek's user avatar
2votes
1answer
447views

PHP Mad Libs with OOP and SQL

I've been learning PHP and I've just gotten into using OOP. Classes/objects/methods etc. My end goal is to take an old Mad libs program I did with PHP, and convert it to OOP. The gist of the project ...
jpsweeney94's user avatar
2votes
0answers
84views

One class for MySQL and MSSQL Queries

EDIT BELOW I am trying to create resusable classes for MSSQL and MySQL queries (later also Update and Delete queries). I tried it doing the OOP-way. Here is my result: Einstellungen.vb: ...
PRCV1's user avatar
4votes
1answer
25kviews

Basic object-oriented PHP login, logout, and registration scripts

I am new to OOP in general and have recently started trying to develop object-oriented PHP code instead of relying on a primarily procedural style, as this is a requirement for my studies. One part of ...
Ichi's user avatar
4votes
1answer
1kviews

PHP Application layers

I'm dealing with design layers of an application. Basically what I've so far are: Business Architecture: Client-Server Techonologies: PHP+MySQL, HTML5, JS, 3rd parties APIs My app Data Sources: MySql ...
jcruz's user avatar
2votes
3answers
2kviews

Connection to MySQL database

I'd created a C# class to connect to a MySQL database (Connection.cs) and a separate class for the user validation (User.cs). Connection.cs ...
user161914's user avatar
1vote
2answers
1kviews

Custom PDO wrapper class

I somewhat recently asked a question on here for advice on a PDO function that I had written. I got some good advice from a user, and went with it. I had used that function for about 3 months which is ...
GrumpyCrouton's user avatar
5votes
1answer
204views

Automatic database migration system

Github here: https://github.com/cmancone/mygrations I'm working on a different kind of database migration system for helping manage web applications. I asked a question about part of the system just ...
Conor Mancone's user avatar
5votes
1answer
101views

Resolving MySQL 1215 errors in a declarative MySQL migration system

Github here: https://github.com/cmancone/mygrations I'm building a migration system for MySQL that operates in a very different way than the usual. Rather than recording changes in the database, the ...
Conor Mancone's user avatar
8votes
1answer
222views

A PHP API which has an endpoint for processing a user's facebook login details

I'm working on a PHP API for my angular JS Phonegap application. At the moment I'm focusing on working with a user's facebook public profile data. I'll explain the process a little first: The user ...
Sarah's user avatar
5votes
1answer
6kviews

A Discord bot that connects to a local database (OOP)

I am currently working on a Discord bot as a way to learn and practice Python. I have been trying to learn object-oriented programming, and apply the "don't repeat yourself" principle. The code ...
braycarlson's user avatar

153050per page
close